﻿@using DirectSell.Model.Message
@using Webdiyer.WebControls.Mvc;
@model PagedList<Messages>
<table class="table table-bordered table-striped">
    <tr>
        <th>序号</th>
         <th>留言</th>
        <th>发送人</th>
        <th>日期</th>
        <th>状态</th>
    </tr>
    @{ int i = 0;}
    @foreach (var item in Model)
    {
        <tr>
            <td>@(Model.StartItemIndex + i++)</td>
            <td><u style="cursor:pointer" class="links" onclick="show_msg('@item.Title', '/User/Message/ShowMsg?id=@item.Id')">@item.Title</u></td>
            <td>@item.SendName</td>
            <td>@item.CreateDate</td>
            @if (item.State == 0)
            {
                <td>未读|<button class="btn btn-info" type="button" onclick="Alread('@item.Id')">标为已读</button></td>
              
            }
            else
            {
                <td><p style="color:cornflowerblue">已读</p></td>
            }
           
        </tr>
    }
</table>
